package com.didi.gulimall.api;

import com.didi.gulimall.api.impl.MemberApiServiceImpl;
import com.didi.gulimall.auth.vo.SocialUser;
import com.didi.gulimall.auth.vo.UserLoginVo;
import com.didi.gulimall.auth.vo.UserRegistVo;
import com.didi.gulimall.common.utils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * @author 10626
 */
@FeignClient(value = "gulimall-member", fallback = MemberApiServiceImpl.class)
public interface MemberApiService {

    @PostMapping("member/regist")
    R registered(@RequestBody UserRegistVo memberRegistVo);


    @PostMapping("member/login")
    R login(@RequestBody UserLoginVo memberLoginVo);

    @PostMapping("member/oauth/weibo/login")
    R oauthweibologin(@RequestBody SocialUser socialUser);
}
